It is known to provide an electromechanical time switch in which the switching times can be set relative to the time of sunset or sunrise at the location of use: such time switches are usually known as solar time switches. However, because of their electromechanical construction, these time switches are complex and expensive to manufacture, and relatively inflexible to use. It is therefore an object of the present invention to provide an electronic solar time switch in which at least some of the drawbacks of electromechanical solar time switches are alleviated.